package com.sinodata.bsm.common.vo;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;

/**
 * CollectParam entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "COLLECT_PARAM")
public class CollectParam implements java.io.Serializable, Cloneable {

    /**
     * serialVersionUID
     */
    private static final long serialVersionUID = -2826933207996550852L;

    // Fields 
    private Long id;
    private String paramName;
    private String paramValue;
    private Long collectTaskId;

    // Constructors

    /** default constructor */
    public CollectParam() {
    }

    /** minimal constructor */
    public CollectParam(Long id) {
        this.id = id;
    }

    /** full constructor */
    public CollectParam(Long id, String paramName, String paramValue, Long collectTaskId) {
        this.id = id;
        this.paramName = paramName;
        this.paramValue = paramValue;
        this.collectTaskId = collectTaskId;
    }

    // Property accessors
    @Id
    @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "sequence")
    @SequenceGenerator(name = "sequence", sequenceName = "COLLECT_PARAM_SEQ")
    @Column(name = "ID", unique = true, nullable = false, precision = 18, scale = 0)
    public Long getId() {
        return this.id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    @Column(name = "PARAM_NAME", length = 256)
    public String getParamName() {
        return this.paramName;
    }

    public void setParamName(String paramName) {
        this.paramName = paramName;
    }

    @Column(name = "PARAM_VALUE", length = 2048)
    public String getParamValue() {
        return this.paramValue;
    }

    public void setParamValue(String paramValue) {
        this.paramValue = paramValue;
    }

    @Column(name = "COLLECT_TASK_ID", precision = 18, scale = 0)
    public Long getCollectTaskId() {
        return this.collectTaskId;
    }

    public void setCollectTaskId(Long collectTaskId) {
        this.collectTaskId = collectTaskId;
    }

    @Override
    public CollectParam clone() throws CloneNotSupportedException {
        CollectParam testClone = null;
        try {
            testClone = (CollectParam) super.clone();
            testClone.setId(null);
        } catch (CloneNotSupportedException e) {
            e.printStackTrace();
        }
        return testClone;

    }

    @Override
    public String toString() {
        return "CollectParam [id=" + id + ", paramName=" + paramName + ", paramValue=" + paramValue + ", collectTaskId=" + collectTaskId + "]";
    }

}